package com.ys.p1.method;

/**
 * @author CodeYang
 * @Description :
 * 2.定义方法：打印指定行和列的矩形
 * @Date 2020/12/8 21:11
 */
public class 定义方法打印行和列 {
    public static void main(String[] args) {
        printStr(4,5,"*");
    }
    static void printStr(int row,int column,String str){
        for (int i = 0; i < row; i++) {
            for (int j = 0; j <column ; j++) {
                System.out.print(str);
            }
            System.out.println();
        }
    }
}
